<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <!-- Import style -->
    <link rel="stylesheet" href="https://unpkg.com/element-plus/dist/index.css" />
    <!-- Import Vue 3 -->
    <script src="https://unpkg.com/vue@3"></script>
    <!-- Import component library -->
    <script src="https://unpkg.com/element-plus"></script
</head>
<body>
    <div id="app">
        <el-row>
            <el-col :span="12">
                <el-button type="primary" @click="isShow = !isShow">切换显示状态</el-button>
                <div v-show="isShow">
                    <img style="width: 400px; height: 600px;" src="https://pic.rmb.bdstatic.com/bjh/down/6c348191c66bf100287f8c3b7dd1422c.png">
                </div>
            </el-col>
            <el-col :span="12">
                <el-button type="success" @click="age++">年龄+1</el-button>
                <el-button type="danger" @click="age=age-1">年龄-1</el-button>
                <p>年龄满足18岁，可以入党。目前年纪：{{age}}</p>
                <img v-show="age>=18" src="https://img0.baidu.com/it/u=2359181516,2710781128&fm=253&fmt=auto&app=138&f=JPEG?w=889&h=500">
            </el-col>
          </el-row>     
    </div>
</body>
<script>
    const App={
        data(){
            return{
                isShow:false,
                age:18,
            }
        },
        methods:{}
    }
    Vue.createApp(App).use(ElementPlus).mount("#app")
</script>
</html>